package com.bf.electroplating.pojo.enums;

import lombok.Data;
import lombok.Getter;

@Getter
public enum PubDataHistoryTypeEnum {


	INSERT("1", "录入信息"),
	UPDATE("2", "变更信息");


	private final String code;
	private final String desc;

	private PubDataHistoryTypeEnum(String code, String desc) {
		this.code = code;
		this.desc = desc;
	}

	public static String getDesc(String code) {
		for (PubDataHistoryTypeEnum item : PubDataHistoryTypeEnum.values()) {
			if (item.getCode().equals(code)) {
				return item.getDesc();
			}
		}
		return null;
	}


}
